<template>
    <div>
        <div class="whiteBg">
            <div class="block_div">
                <p class="block_num">{{blockInfo.usrId}}</p>
                <p class="block_text">您的用户编号</p>
            </div>
            <div class="block_div borderNone">
                <p class="block_num">{{blockInfo.dataPwd}}</p>
                <p class="block_text">您的密钥</p>
            </div>
        </div>
        <div class="whiteBg margin_top">
            <div class="block_div borderNone">
                <p class="block_text fontColor3">您的公示地址</p>
                <p class="block_num">{{blockInfo.blockAddress}}</p>
            </div>
        </div>
    </div>
</template>
<script>
    import * as types from '../../vuex/types.js'
    import {ownBlockInfor} from '../../service/getData3.js'
    import { mapState } from 'vuex'

    export default {
        data: () => ({
          blockInfo: {}
        }),
        computed: {
          ...mapState({
            userInfo:state => state.user.userInfo
          }),
        },
        created:function(){
            let usrId = this.userInfo.usrId
            ownBlockInfor({usrId}).then(res => {
              if (res.content) {
                this.blockInfo = res.content.block
//                this.$store.commit("addrKey",res.content.block);
              }
            })
        }
    }
</script>
<style>

</style>
